package trajectories;

public class LineTrajectorie extends Trajectory {

    @Override
    public void move() {
        if (TRAJECTORY_DIRECTION == Directions.RIGHT) {
            x = x + 1;
            if (x == 400) {
                TRAJECTORY_DIRECTION = Directions.LEFT;
            }
        } else if (TRAJECTORY_DIRECTION == Directions.LEFT) {
            x = x - 1;
            if (x == 100) {
                TRAJECTORY_DIRECTION = Directions.RIGHT;
            }
        }

    }
}
